<template>
  <Bespeak class="subassembly-properties" :config="config" :formConfig="selectedSubassembly"></Bespeak>
</template>

<script>
import Bespeak from '@/components/Bespeak'
import { components } from '@/assembly/index.js'
export default {
  components: { Bespeak },
  props: {
    selectedSubassembly: {
      type: Object,
      require: true
    }
  },
  data() {
    return {

    }
  },
  computed: {
    config() {
      console.log(27, components);
      console.log(28, this.selectedSubassembly, this.selectedSubassembly.type);
      const config = components.filter(item => item.type === this.selectedSubassembly.type)?.[0]
      console.log(26, config.formConfig);
      return config.formConfig
    }
  },
  created() {
    console.log(20, this.selectedSubassembly);
  },
  methods: {

  },
}
</script>

<style scoped lang="scss">
.subassembly-properties {}
</style>